<script>
    $(function() {
        $( "#tabs" ).tabs();
    });
</script>

<div style="padding-left: 10px;padding-top: 10px; width: 100%;height: 110%;background-image:url(<?php echo URL::base()?>assets/images/background.jpg)" align="left" class="ui-widget ui-corner-all">
<table width="99%" class="ui-widget ui-widget-content ui-corner-all">
       <thead><tr class="ui-widget-header"><td>ย้อนกลับ</td><td>ครั้งที่</td><td>คุณหมอเจ้าของไข้</td><td>คุณหมอที่ปรึกษา</td><td>สถานที่ทำการตรวจ</td><td>วันเวลาที่เริ่มตรวจ</td><td>วันเวลาที่ตรวจเสร็จ</td></tr></thead>
       <?php
         echo  "<tr>
                    <td align=center><a href='".URL::base()."patient/profile/".$history['p_id']."' target=''>". html::image('assets/icon/arrow_left_green_48.png',array('width' => '36', 'height' => '36'))."</a></td>
                    <td>".$history['c_id']."</td>
                    <td>".$history['doctor_name']."</td>
                    <td>".$history['consult_doctor_name']."</td>
                    <td>".$history['pp_name']."</td>
                    <td>".$history['consult_start']."</td>
                    <td>".$history['consult_end']."</td>                    
               </tr>";

       ?>
</table>
    <br>

<table width="99%" class="ui-widget ui-widget-content ui-corner-all">
    <tr>
        <td align="left" valign="top" style="padding: 10px">
            <div id="tabs">
                <ul>
                    <li><a href="#tabs-1" style="font-size: 12px">NIHSS</a></li>
                    <li><a href="#tabs-2" style="font-size: 12px">Stroke Data</a></li>
                    <li><a href="#tabs-3" style="font-size: 12px">Stroke Physical examination</a></li>
                    <li><a href="#tabs-4" style="font-size: 12px">Laboratory screen for exclusion</a></li>
                    <li><a href="#tabs-5" style="font-size: 12px">ประเมินทางประสาทวิทยา</a></li>
                </ul>

                <div id="tabs-1">
                    <table class="ui-widget ui-widget-content ui-corner-all">
                        <tr>
                            <td valign="top"> 1a. Level of consciousness </td>
                            <td style="padding-left: 5px">
                                <select name="no1a" id="no1a">
                                    <option value="0" <?php echo isset($nihss['no1a'])? ($nihss['no1a'] == 0? "selected": "") : "" ?>>Alert (0)</option>
                                    <option value="1" <?php echo isset($nihss['no1a'])? ($nihss['no1a'] == 1? "selected": "") : "" ?>>Drowsy (1)</option>
                                    <option value="2" <?php echo isset($nihss['no1a'])? ($nihss['no1a'] == 2? "selected": "") : "" ?>>Stuporous (2)</option>
                                    <option value="3" <?php echo isset($nihss['no1a'])? ($nihss['no1a'] == 3? "selected": "") : "" ?>>Coma (3)</option>
                                </select>
                            </td>
                        </tr>
                        <tr bgcolor="#E4E4E4">
                            <td valign="top"> 1b. Two questions ถามอายุและเดือน </td>
                            <td style="padding-left: 5px">
                                <select name="no1b" id="no1b">
                                    <option value="0" <?php echo isset($nihss['no1b'])? ($nihss['no1b'] == 0? "selected": "") : "" ?>>Both correct (0)</option>
                                    <option value="1" <?php echo isset($nihss['no1b'])? ($nihss['no1b'] == 1? "selected": "") : "" ?>>One correct (1)</option>
                                    <option value="2" <?php echo isset($nihss['no1b'])? ($nihss['no1b'] == 2? "selected": "") : "" ?>>None correct (2)</option>
                                </select>
                            </td>
                        </tr>
                        <tr>
                            <td valign="top"> 1c. Two commands หลับตา ลืมตาและกำมือ แบมือ  </td>
                            <td style="padding-left: 5px">
                                <select name="no1c" id="no1c">
                                    <option value="0" <?php echo isset($nihss['no1c'])? ($nihss['no1c'] == 0? "selected": "") : "" ?>>Obeys both (0)</option>
                                    <option value="1" <?php echo isset($nihss['no1c'])? ($nihss['no1c'] == 1? "selected": "") : "" ?>>Obeys none (1)</option>
                                </select>
                            </td>
                        </tr>
                        <tr bgcolor="#E4E4E4">
                            <td valign="top"> 2. Best gaze มองด้านข้าง  </td>
                            <td style="padding-left: 5px">
                                <select name="no2" id="no2">
                                    <option value="0" <?php echo isset($nihss['no2'])? ($nihss['no2'] == 0? "selected": "") : "" ?>>Normal (0)</option>
                                    <option value="1" <?php echo isset($nihss['no2'])? ($nihss['no2'] == 1? "selected": "") : "" ?>>Partial gaze palsy (1)</option>
                                    <option value="2" <?php echo isset($nihss['no2'])? ($nihss['no2'] == 2? "selected": "") : "" ?>>Forced deviation (2)</option>
                                </select>
                            </td>
                        </tr>
                        <tr>
                            <td valign="top"> 3. Best visual (visual field)</td>
                            <td style="padding-left: 5px">
                                <select name="no3" id="no3">
                                    <option value="0" <?php echo isset($nihss['no3'])? ($nihss['no3'] == 0? "selected": "") : "" ?>>No visual loss (0)</option>
                                    <option value="1" <?php echo isset($nihss['no3'])? ($nihss['no3'] == 1? "selected": "") : "" ?>>Partial hemianopia (1)</option>
                                    <option value="2" <?php echo isset($nihss['no3'])? ($nihss['no3'] == 2? "selected": "") : "" ?>>Complete  hemianopia (2)</option>
                                    <option value="3" <?php echo isset($nihss['no3'])? ($nihss['no3'] == 3? "selected": "") : "" ?>>Bilateral hemianopia (3)</option>
                                </select>
                            </td>
                        </tr>
                        <tr bgcolor="#E4E4E4">
                            <td valign="top"> 4. Facial palsy</td>
                            <td style="padding-left: 5px">
                                <select name="no4" id="no4">
                                    <option value="0" <?php echo isset($nihss['no4'])? ($nihss['no4'] == 0? "selected": "") : "" ?>>Normal (0)</option>
                                    <option value="1" <?php echo isset($nihss['no4'])? ($nihss['no4'] == 1? "selected": "") : "" ?>>Minor (1)</option>
                                    <option value="2" <?php echo isset($nihss['no4'])? ($nihss['no4'] == 2? "selected": "") : "" ?>>Partial (2)</option>
                                    <option value="3" <?php echo isset($nihss['no4'])? ($nihss['no4'] == 3? "selected": "") : "" ?>>Complete (3)</option>
                                </select>
                            </td>
                        </tr>
                        <tr>
                            <td valign="top"> 5a. Best Motor Lt arms นั่งยกแขน 90 องศา 10 วินาทีหรือนอนยกแขน 45 องศา</td>
                            <td style="padding-left: 5px">
                                <select name="no5a" id="no5a">
                                    <option value="0" <?php echo isset($nihss['no5a'])? ($nihss['no5a'] == 0? "selected": "") : "" ?>>No drift (0)</option>
                                    <option value="1" <?php echo isset($nihss['no5a'])? ($nihss['no5a'] == 1? "selected": "") : "" ?>>Drift (1)</option>
                                    <option value="2" <?php echo isset($nihss['no5a'])? ($nihss['no5a'] == 2? "selected": "") : "" ?>>Fall in 10 secs (2)</option>
                                    <option value="3" <?php echo isset($nihss['no5a'])? ($nihss['no5a'] == 3? "selected": "") : "" ?>>No effort against gravity (3)</option>
                                    <option value="4" <?php echo isset($nihss['no5a'])? ($nihss['no5a'] == 4? "selected": "") : "" ?>>No movement (4)</option>
                                </select>
                            </td>
                        </tr>
                        <tr bgcolor="#E4E4E4">
                            <td valign="top"> 5b. Best Motor Rt arms นั่งยกแขน 90 องศา 10 วินาทีหรือนอนยกแขน 45 องศา</td>
                            <td style="padding-left: 5px">
                                <select name="no5b" id="no5b">
                                    <option value="0" <?php echo isset($nihss['no5b'])? ($nihss['no5b'] == 0? "selected": "") : "" ?>>No drift (0)</option>
                                    <option value="1" <?php echo isset($nihss['no5b'])? ($nihss['no5b'] == 1? "selected": "") : "" ?>>Drift (1)</option>
                                    <option value="2" <?php echo isset($nihss['no5b'])? ($nihss['no5b'] == 2? "selected": "") : "" ?>>Fall in 10 secs (2)</option>
                                    <option value="3" <?php echo isset($nihss['no5b'])? ($nihss['no5b'] == 3? "selected": "") : "" ?>>No effort against gravity (3)</option>
                                    <option value="4" <?php echo isset($nihss['no5b'])? ($nihss['no5b'] == 4? "selected": "") : "" ?>>No movement (4)</option>
                                </select>
                            </td>
                        </tr>
                        <tr>
                            <td valign="top"> 6a. Best Motor Lt legs นอนยกขา 30 องศา 5 วินาที </td>
                            <td style="padding-left: 5px">
                                <select name="no6a" id="no6a">
                                    <option value="0" <?php echo isset($nihss['no6a'])? ($nihss['no6a'] == 0? "selected": "") : "" ?>>No drift (0)</option>
                                    <option value="1" <?php echo isset($nihss['no6a'])? ($nihss['no6a'] == 1? "selected": "") : "" ?>>Drift (1)</option>
                                    <option value="2" <?php echo isset($nihss['no6a'])? ($nihss['no6a'] == 2? "selected": "") : "" ?>>Fall in 10 secs (2)</option>
                                    <option value="3" <?php echo isset($nihss['no6a'])? ($nihss['no6a'] == 3? "selected": "") : "" ?>>No effort against gravity (3)</option>
                                    <option value="4" <?php echo isset($nihss['no6a'])? ($nihss['no6a'] == 4? "selected": "") : "" ?>>No movement (4)</option>
                                </select>
                            </td>
                        </tr>
                        <tr bgcolor="#E4E4E4">
                            <td valign="top"> 6b. Best Motor Rt legs นอนยกขา 30 องศา 5 วินาที </td>
                            <td style="padding-left: 5px">
                                <select name="no6b" id="no6b">
                                    <option value="0" <?php echo isset($nihss['no6b'])? ($nihss['no6b'] == 0? "selected": "") : "" ?>>No drift (0)</option>
                                    <option value="1" <?php echo isset($nihss['no6b'])? ($nihss['no6b'] == 1? "selected": "") : "" ?>>Drift (1)</option>
                                    <option value="2" <?php echo isset($nihss['no6b'])? ($nihss['no6b'] == 2? "selected": "") : "" ?>>Fall in 10 secs (2)</option>
                                    <option value="3" <?php echo isset($nihss['no6b'])? ($nihss['no6b'] == 3? "selected": "") : "" ?>>No effort against gravity (3)</option>
                                    <option value="4" <?php echo isset($nihss['no6b'])? ($nihss['no6b'] == 4? "selected": "") : "" ?>>No movement (4)</option>
                                </select>
                            </td>
                        </tr>
                        <tr>
                            <td valign="top"> 7. Limb Ataxia </td>
                            <td style="padding-left: 5px">
                                <select name="no7" id="no7">
                                    <option value="0" <?php echo isset($nihss['no7'])? ($nihss['no7'] == 0? "selected": "") : "" ?>>Absent (0)</option>
                                    <option value="1" <?php echo isset($nihss['no7'])? ($nihss['no7'] == 1? "selected": "") : "" ?>>Upper or lower limb (1)</option>
                                    <option value="2" <?php echo isset($nihss['no7'])? ($nihss['no7'] == 2? "selected": "") : "" ?>>Upper & lower limb (2)</option>
                                </select>
                            </td>
                        </tr>
                        <tr bgcolor="#E4E4E4">
                            <td valign="top"> 8. Sensory </td>
                            <td style="padding-left: 5px">
                                <select name="no8" id="no8">
                                    <option value="0" <?php echo isset($nihss['no8'])? ($nihss['no8'] == 0? "selected": "") : "" ?>>Normal (0)</option>
                                    <option value="1" <?php echo isset($nihss['no8'])? ($nihss['no8'] == 1? "selected": "") : "" ?>>Partial loss (1)</option>
                                    <option value="2" <?php echo isset($nihss['no8'])? ($nihss['no8'] == 2? "selected": "") : "" ?>>Dense loss (2)</option>
                                </select>
                            </td>
                        </tr>
                        <tr>
                            <td valign="top"> 9. Best language Aphasia </td>
                            <td style="padding-left: 5px">
                                <select name="no9" id="no9">
                                    <option value="0" <?php echo isset($nihss['no9'])? ($nihss['no9'] == 0? "selected": "") : "" ?>>No aphasia (0)</option>
                                    <option value="1" <?php echo isset($nihss['no9'])? ($nihss['no9'] == 1? "selected": "") : "" ?>>Mild to moderate (1)</option>
                                    <option value="2" <?php echo isset($nihss['no9'])? ($nihss['no9'] == 2? "selected": "") : "" ?>>Severe (2)</option>
                                    <option value="3" <?php echo isset($nihss['no9'])? ($nihss['no9'] == 3? "selected": "") : "" ?>>Mute (3)</option>
                                </select>
                            </td>
                        </tr>
                        <tr bgcolor="#E4E4E4">
                            <td valign="top"> 10. Dysarthria </td>
                            <td style="padding-left: 5px">
                                <select name="no10" id="no10">
                                    <option value="0" <?php echo isset($nihss['no10'])? ($nihss['no10'] == 0? "selected": "") : "" ?>>Normal articulation (0)</option>
                                    <option value="1" <?php echo isset($nihss['no10'])? ($nihss['no10'] == 1? "selected": "") : "" ?>>Mild to moderate (1)</option>
                                    <option value="2" <?php echo isset($nihss['no10'])? ($nihss['no10'] == 2? "selected": "") : "" ?>>Severe (2)</option>
                                </select>
                            </td>
                        </tr>
                        <tr>
                            <td valign="top"> 11. Neglect </td>
                            <td style="padding-left: 5px">
                                <select name="no11" id="no11">
                                    <option value="0" <?php echo isset($nihss['no11'])? ($nihss['no11'] == 0? "selected": "") : "" ?>>No neglect (0)</option>
                                    <option value="1" <?php echo isset($nihss['no11'])? ($nihss['no11'] == 1? "selected": "") : "" ?>>Sensory or visual (1)</option>
                                    <option value="2" <?php echo isset($nihss['no11'])? ($nihss['no11'] == 2? "selected": "") : "" ?>>Sensory & visual (2)</option>
                                </select>
                            </td>
                        </tr>
                    </table>
                </div>

                <div id="tabs-2">
                    <table id="users" class="ui-widget ui-widget-content ui-corner-all" width="100%" style="margin-top: 10px;padding-bottom: 10px;">
                        <thead>
                            <tr class="ui-widget-header ">
                                <th colspan="7" align="left" style="padding: 10px">Stroke Data</th>
                            </tr>
                        </thead>
                        <tbody>
                            <tr>
                                <td colspan="2">
                                    <table width="100%"><tr>
                                            <td>วันที่ </td><td><u>12-01-2010</u></td><td>Name </td><td><u>อิสริยพล สิริวัฒน์</u></td><td>HN</td><td></td>
                                        </tr></table>
                                </td>
                            </tr>
                            <tr>
                                <td colspan="2">
                                    <table width="100%">
                                        <tr>
                                            <td>อายุ</td><td width="50" align="right">ปี</td><td>วันเดือนปีเกิด</td><td></td><td>มีอาการก่อนมาโรงพยาบาล</td><td>
                                                <input type="text" size="3" name="std_before_d" id="std_before_d" >วัน</td><td>
                                                <input type="text" size="3" name="std_before_h" id="std_before_h">ชั่วโมง </td><td>
                                                <input type="text" size="3" name="std_before_m" id="std_before_m"> นาที</td>
                                        </tr>
                                    </table>
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    CC:
                                </td>
                                <td><input type="text" size="70" id="cc" name="cc" value="<?php echo isset($std['cc'])? $std['cc']:"" ?>"></td>
                            </tr>
                            <tr>
                                <td>
                                    PI:
                                </td>
                                <td>
                                    <textarea cols="70" rows="3" id="PI" name="PI"><?php echo isset($std['PI'])?$std['PI']:"" ?></textarea>
                                </td>
                            </tr>
                            <tr>
                                <td colspan="2">
                                    <table style="margin-left: 5px">
                                        <tr><td width="100">Headache</td><td><input id="headache" name="headache" type="radio" value="yes" <?php echo isset($std['headache'])? ($std['headache'] == "yes"? "checked": "") : "" ?>>Yes</td><td><input id="headache" name="headache" type="radio" value="no" <?php echo isset($std['headache'])? ($std['headache'] == "no"? "checked": "") : "" ?>>No</td><td></td><td></td></tr>
                                        <tr><td width="100"></td><td>ข้างที่ปวดรุนแรง</td><td><input id="sideheadache" name="sideheadache" type="radio" value="l" <?php echo isset($std['sideheadache'])? ($std['sideheadache'] == "l"? "checked": "") : "" ?>>Left</td><td><input id="sideheadache" name="sideheadache" type="radio" value="r" <?php echo isset($std['sideheadache'])? ($std['sideheadache'] == "r"? "checked": "") : "" ?>>Right</td><td><input id="sideheadache" name="sideheadache" type="radio" value="b" <?php echo isset($std['sideheadache'])? ($std['sideheadache'] == "b"? "checked": "") : "" ?>>Bilateral</td></tr>
                                        <tr><td width="100"></td><td>ความรุนแรง</td><td><input id="muchheadache" name="muchheadache" type="radio" value="ml" <?php echo isset($std['muchheadache'])? ($std['muchheadache'] == "ml"? "checked": "") : "" ?>>Mild</td><td><input id="muchheadache" name="muchheadache" type="radio" value="mr" <?php echo isset($std['muchheadache'])? ($std['muchheadache'] == "mr"? "checked": "") : "" ?>>Moderate</td><td><input id="muchheadache" name="muchheadache" type="radio" value="s" <?php echo isset($std['muchheadache'])? ($std['muchheadache'] == "s"? "checked": "") : "" ?>>Severe</td></tr>
                                        <tr><td width="100"></td><td>ตำแหน่งการปวด</td><td><input id="areaheadache" name="areaheadache" type="radio" value="f" <?php echo isset($std['areaheadache'])? ($std['areaheadache'] == "f"? "checked": "") : "" ?>>หน้าฝาก</td><td><input id="areaheadache" name="areaheadache" type="radio" value="l" <?php echo isset($std['areaheadache'])? ($std['areaheadache'] == "l"? "checked": "") : "" ?>>ท้ายทอย</td><td><input id="areaheadache" name="areaheadache" type="radio" value="k" <?php echo isset($std['areaheadache'])? ($std['areaheadache'] == "k"? "checked": "") : "" ?>>ขมับ</td>
                                            <td><input id="areaheadache" name="areaheadache" type="radio" value="o" <?php echo isset($std['areaheadache'])? ($std['areaheadache'] == "o"? "checked": "") : "" ?>>อื่นๆ<input type="text" id="areaheadache_other" name="areaheadache_other" value="<?php echo isset($std['areaheadache_other'])? $std['areaheadache_other']:"" ?>"></td></tr>
                                    </table>
                                </td>
                            </tr>
                            <tr>
                                <td valign="top">
                                    PH:
                                </td>
                                <td>
                                    <table>
                                        <tr><td><table><tr><td><input type="checkbox" id="ph_ht_yn" name="ph_ht_yn" <?php echo isset($std['ph_ht_yn'])? ($std['ph_ht_yn'] == "on"? "checked": "") : "" ?>>HT</td><td>
                                                            <input type="text" id="ph_ht_yrs" name="ph_ht_yrs" size="3" value="<?php echo isset($std['ph_ht_yrs'])?$std['ph_ht_yrs']:"" ?>">Yrs.</td><td>Med</td><td>
                                                            <input id="ph_ht_med" name="ph_ht_med" type="text" size="15" value="<?php echo isset($std['ph_ht_med'])?$std['ph_ht_med']:"" ?>"></td>
                                                        <td><input type="checkbox" id="ph_dm_yn" name="ph_dm_yn" <?php echo isset($std['ph_dm_yn'])? ($std['ph_dm_yn'] == "on"? "checked": "") : "" ?>>DM</td><td>
                                                            <input type="text" id="ph_dm_yrs" name="ph_dm_yrs" size="3" value="<?php echo isset($std['ph_dm_yrs'])?$std['ph_dm_yrs']:"" ?>">Yrs.</td><td>Med</td><td>
                                                            <input type="text" id="ph_dm_med" name="ph_dm_med" size="15" value="<?php echo isset($std['ph_dm_med'])?$std['ph_dm_med']:"" ?>"></td></tr></table></td></tr>
                                        <tr><td><table><tr><td><input type="checkbox" id="ph_dyslipidemia_yn"  name="ph_dyslipidemia_yn" <?php echo isset($std['ph_dyslipidemia_yn'])? ($std['ph_dyslipidemia_yn'] == "on"? "checked": "") : "" ?>>Dyslipidemia</td><td>
                                                            <input type="text" size="3" id="ph_dyslipidemia_yrs" name="ph_dyslipidemia_yrs" value="<?php echo isset($std['ph_dyslipidemia_yrs'])?$std['ph_dyslipidemia_yrs']:"" ?>">Yrs.</td><td>Med</td><td>
                                                            <input type="text" size="15" id="ph_dyslipidemia_med" name="ph_dyslipidemia_med" value="<?php echo isset($std['ph_dyslipidemia_med'])?$std['ph_dyslipidemia_med']:"" ?>"></td></tr></table></td></tr>
                                        <tr><td><table><tr><td><input type="checkbox" id="ph_smoking_yn" name="ph_smoking_yn" <?php echo isset($std['ph_smoking_yn'])? ($std['ph_smoking_yn'] == "on"? "checked": "") : "" ?>>Smoking</td><td>
                                                            <input type="text" size="3" id="ph_smoking_pack" name="ph_smoking_pack" value="<?php echo isset($std['ph_smoking_pack'])?$std['ph_smoking_pack']:"" ?>">Packs/day</td><td>
                                                            <input type="text" size="3" id="ph_smoking_yrs" name="ph_smoking_yrs" value="<?php echo isset($std['ph_smoking_yrs'])?$std['ph_smoking_yrs']:"" ?>"></td><td>Yrs.</td><td>Quit</td><td>
                                                            <input type="text" size="3" id="ph_smoking_qyrs" name="ph_smoking_qyrs" value="<?php echo isset($std['ph_smoking_qyrs'])?$std['ph_smoking_qyrs']:"" ?>"></td><td>Yrs.</td></tr></table></td></tr>
                                        <tr><td><table><tr><td><input type="checkbox" id="ph_heart_disease_yn" name="ph_heart_disease_yn" <?php echo isset($std['ph_heart_disease_yn'])? ($std['ph_heart_disease_yn'] == "on"? "checked": "") : "" ?>>Heart disease type
                                                            <input type="text" size="15" id="ph_heart_disease_type" name="ph_heart_disease_type" value="<?php echo isset($std['ph_heart_disease_type'])?$std['ph_heart_disease_type']:"" ?>"></td><td>Med</td><td>
                                                            <input type="text" size="15" id="ph_heart_disease_med" name="ph_heart_disease_med" value="<?php echo isset($std['ph_heart_disease_med'])?$std['ph_heart_disease_med']:"" ?>"></td></tr></table></td></tr>
                                        <tr><td><table><tr><td><input type="checkbox" id="ph_others_yn" name="ph_others_yn" <?php echo isset($std['ph_others_yn'])? ($std['ph_others_yn'] == "on"? "checked": "") : "" ?>>Others</td><td>
                                                            <input type="text" size="25" id="ph_others" name="ph_others" value="<?php echo isset($std['ph_others'])?$std['ph_others']:"" ?>"></td></tr></table></td></tr>
                                    </table>
                                </td>
                            </tr>
                            <tr><td colspan="4" align="center"></td></tr>
                        </tbody>
                    </table>
                </div>

                <div id="tabs-3">
                    <table id="users" class="ui-widget ui-widget-content ui-corner-all" width="102%" style="margin-top: 5px;padding-bottom: 10px;">
                        <thead>
                            <tr class="ui-widget-header ">
                                <th colspan="7" align="left" style="padding: 10px">Stroke Physical examination</th>
                            </tr>
                        </thead>
                        <tbody>
                            <tr><td colspan="2">
                                    <table>
                                        <tr><td><b><u>BP</u></b>:
                                                <input type="text" size="2" name="BPmin" id="BPmin" value="<?php echo isset($stp['BPmin'])?$stp['BPmin']:"" ?>">/
                                                <input type="text" size="3" name="BPmax" id="BPmax" value="<?php echo isset($stp['BPmax'])?$stp['BPmax']:"" ?>">
                                                ,<b><u>PR</u></b>
                                                <input type="text" size="2" id="PR" name="PR" value="<?php echo isset($stp['PR'])?$stp['PR']:"" ?>"> /
                                                min regular
                                                <input type="radio" id="PRminYN" name="PRminYN" value="y" <?php echo isset($stp['PRminYN'])? ($stp['PRminYN'] == "y"? "checked": "") : "" ?>>Y/
                                                <input type="radio" id="PRminYN" name="PRminYN" value="n" <?php echo isset($stp['PRminYN'])? ($stp['PRminYN'] == "n"? "checked": "") : "" ?>>N</td></tr>
                                        <tr><td colspan="2" style="padding-left: 5px"><b><u>Carotid bruit</u></b>
                                                Lt: <input type="radio" id="CarotidLt" name="CarotidLt" value="y" <?php echo isset($stp['CarotidLt'])? ($stp['CarotidLt'] == "y"? "checked": "") : "" ?>>Y/
                                                <input type="radio" id="CarotidLt" name="CarotidLt" value="n" <?php echo isset($stp['CarotidLt'])? ($stp['CarotidLt'] == "n"? "checked": "") : "" ?>>N
                                                Rt: <input type="radio" id="CarotidRt" name="CarotidRt" value="y" <?php echo isset($stp['CarotidRt'])? ($stp['CarotidRt'] == "y"? "checked": "") : "" ?>>Y/
                                                <input type="radio" id="CarotidRt" name="CarotidRt" value="n" <?php echo isset($stp['CarotidRt'])? ($stp['CarotidRt'] == "n"? "checked": "") : "" ?>>N</td></tr>
                                    </table>
                                </td></tr>
                            <tr><td colspan="2"><b><u>Heart</u></b>:
                                    <input type="text" size="30" id="Heart" name="Heart" value="<?php echo isset($stp['Heart'])?$stp['Heart']:"" ?>"></td></tr>
                            <tr><td colspan="2"><b><u>Consciousness</u></b>:
                                    E <input type="text" size="1" id="ConsciousnessE" name="ConsciousnessE" value="<?php echo isset($stp['ConsciousnessE'])?$stp['ConsciousnessE']:"" ?>">
                                    M <input type="text" size="1" id="ConsciousnessM" name="ConsciousnessM" value="<?php echo isset($stp['ConsciousnessM'])?$stp['ConsciousnessM']:"" ?>">
                                    V <input type="text" size="1" id="ConsciousnessV" name="ConsciousnessV" value="<?php echo isset($stp['ConsciousnessV'])?$stp['ConsciousnessV']:"" ?>"> </td></tr>
                            <tr><td colspan="2"><i><b>Orientation</b></i>:
                                    time <input type="text" size="5" id="OrientationTime" name="OrientationTime" value="<?php echo isset($stp['OrientationTime'])?$stp['OrientationTime']:"" ?>">
                                    place <input type="text" size="5" id="OrientationPlace" name="OrientationPlace" value="<?php echo isset($stp['OrientationPlace'])?$stp['OrientationPlace']:"" ?>">
                                    person <input type="text" size="5" id="OrientationPerson" name="OrientationPerson" value="<?php echo isset($stp['OrientationTime'])?$stp['OrientationTime']:"" ?>"></td></tr>
                            <tr><td colspan="2"><u><b>Speech</b></u>:
                                    <input type="radio" id="Speech" name="Speech" value="d" <?php echo isset($stp['Speech'])? ($stp['Speech'] == "d"? "checked": "") : "" ?>> dysarthric
                                    <input type="radio" id="Speech" name="Speech" value="a" <?php echo isset($stp['Speech'])? ($stp['Speech'] == "a"? "checked": "") : "" ?>> aphasic
                                    <input type="radio" id="Speech" name="Speech" value="n" <?php echo isset($stp['Speech'])? ($stp['Speech'] == "n"? "checked": "") : "" ?>> normal </td></tr>
                            <tr><td colspan="2"><i><b>Type of aphasia</b></i>:
                                    <input type="radio" id="Aphasia" name="Aphasia" value="m" <?php echo isset($stp['Aphasia'])? ($stp['Aphasia'] == "m"? "checked": "") : "" ?>> motor
                                    <input type="radio" id="Aphasia" name="Aphasia" value="s" <?php echo isset($stp['Aphasia'])? ($stp['Aphasia'] == "s"? "checked": "") : "" ?>> sensory
                                    <input type="radio" id="Aphasia" name="Aphasia" value="g" <?php echo isset($stp['Aphasia'])? ($stp['Aphasia'] == "g"? "checked": "") : "" ?>> global</td></tr>
                            <tr><td><i><b>Fluency</b></i>:
                                    <input type="radio" id="Fluency" name="Fluency" value="n" <?php echo isset($stp['Fluency'])? ($stp['Fluency'] == "n"? "checked": "") : "" ?>> Normal
                                    <input type="radio" id="Fluency" name="Fluency" value="a" <?php echo isset($stp['Fluency'])? ($stp['Fluency'] == "a"? "checked": "") : "" ?>> Abnormal </td>
                                <td><i><b>Comprehension</b></i>:
                                    <input type="radio" id="Comprehension" name="Comprehension" value="n" <?php echo isset($stp['Comprehension'])? ($stp['Comprehension'] == "n"? "checked": "") : "" ?>>Normal
                                    <input type="radio" id="Comprehension" name="Comprehension" value="a" <?php echo isset($stp['Comprehension'])? ($stp['Comprehension'] == "a"? "checked": "") : "" ?>>Abnormal </td></tr>
                            <tr><td><i><b>Paraphasia</b></i>:
                                    <input type="radio" id="Paraphasia" name="Paraphasia" value="n" <?php echo isset($stp['Paraphasia'])? ($stp['Paraphasia'] == "n"? "checked": "") : "" ?>>Normal
                                    <input type="radio" id="Paraphasia" name="Paraphasia" value="a" <?php echo isset($stp['Paraphasia'])? ($stp['Paraphasia'] == "a"? "checked": "") : "" ?>>Abnormal </td><td>
                                    <i><b>Repetition</b></i>:
                                    <input type="radio" id="Repetition" name="Repetition" <?php echo isset($stp['Repetition'])? ($stp['Repetition'] == "n"? "checked": "") : "" ?>>Normal
                                    <input type="radio" id="Repetition" name="Repetition" <?php echo isset($stp['Repetition'])? ($stp['Repetition'] == "a"? "checked": "") : "" ?>>Abnormal </td></tr>
                            <tr><td><i><b>Naming</b></i>:
                                    <input type="radio" id="Naming" name="Naming" value="n" <?php echo isset($stp['Naming'])? ($stp['Naming'] == "n"? "checked": "") : "" ?>>Normal
                                    <input type="radio" id="Naming" name="Naming" value="a" <?php echo isset($stp['Naming'])? ($stp['Naming'] == "a"? "checked": "") : "" ?>>Abnormal  </td></tr>
                            <tr><td colspan="2"> <b><u>Cranial nerves</u></b>:
                                    Eye deviation in primary position
                                    L: <input type="text" size="5" id="CranialL" name="CranialL" value="<?php echo isset($stp['CranialL'])?$stp['CranialL']:"" ?>">
                                    R: <input type="text" size="5" id="CranialR" name="CranialR" value="<?php echo isset($stp['CranialR'])?$stp['CranialR']:"" ?>"></td></tr>
                            <tr><td colspan="2">
                                    <b><u>Horner's syndrome</u></b>:
                                    <input type="radio" id="Horner" name="Horner" value="-" <?php echo isset($stp['Horner'])? ($stp['Horner'] == "-"? "checked": "") : "" ?>>-/
                                    <input type="radio" id="Horner" name="Horner" value="+" <?php echo isset($stp['Horner'])? ($stp['Horner'] == "+"? "checked": "") : "" ?>>+
                                    (
                                    <input type="radio" id="HornerLR" name="HornerLR" value="r" <?php echo isset($stp['HornerLR'])? ($stp['HornerLR'] == "r"? "checked": "") : "" ?>>Rt,
                                    <input type="radio" id="HornerLR" name="HornerLR" value="l" <?php echo isset($stp['HornerLR'])? ($stp['HornerLR'] == "l"? "checked": "") : "" ?>>Lt)
                                    type <input type="text" size="5" id="HornerType" name="HornerType" value="<?php echo isset($stp['HornerType'])?$stp['HornerType']:"" ?>"> </td></tr>
                            <tr><td colspan="2">
                                    <table>
                                        <tr>
                                            <td><i><b>Pupils</b></i>:</td><td>
                                                Lt <input type="text" size="4" id="PupilsLt" name="PupilsLt" value="<?php echo isset($stp['PupilsLt'])?$stp['PupilsLt']:"" ?>"> mm.
                                                <input type="radio" id="PupilsLtc" name="PupilsLtc" value="g" <?php echo isset($stp['PupilsLtc'])? ($stp['PupilsLtc'] == "g"? "checked": "") : "" ?>>good
                                                <input type="radio" id="PupilsLtc" name="PupilsLtc" value="s" <?php echo isset($stp['PupilsLtc'])? ($stp['PupilsLtc'] == "s"? "checked": "") : "" ?>>sluggish
                                                <input type="radio" id="PupilsLtc" name="PupilsLtc" value="n" <?php echo isset($stp['PupilsLtc'])? ($stp['PupilsLtc'] == "n"? "checked": "") : "" ?>>not reactive to light</td></tr>
                                        <tr><td></td><td>
                                                Rt <input type="text" size="4" name="PupilsRt" value="<?php echo isset($stp['PupilsRt'])?$stp['PupilsRt']:"" ?>"> mm.
                                                <input type="radio" id="PupilsRtc" name="PupilsRtc" value="g" <?php echo isset($stp['PupilsRtc'])? ($stp['PupilsRtc'] == "g"? "checked": "") : "" ?>>good
                                                <input type="radio" id="PupilsRtc" name="PupilsRtc" value="s" <?php echo isset($stp['PupilsRtc'])? ($stp['PupilsRtc'] == "s"? "checked": "") : "" ?>>sluggish
                                                <input type="radio" id="PupilsRtc" name="PupilsRtc" value="n" <?php echo isset($stp['PupilsRtc'])? ($stp['PupilsRtc'] == "n"? "checked": "") : "" ?>>not reactive to light</td></tr>
                                    </table></td></tr>
                            <tr><td colspan="2"><b>VA</b>:
                                    Lt <input type="text" size="4" id="VALt" name="VALt" value="<?php echo isset($stp['VALt'])?$stp['VALt']:"" ?>">
                                    Rt <input type="text" size="4" id="VARt" name="VARt" value="<?php echo isset($stp['VARt'])?$stp['VARt']:"" ?>">
                                    <b>VF</b>:
                                    Lt <input type="text" size="4" id="VFLt" name="VFLt" value="<?php echo isset($stp['VFLt'])?$stp['VFLt']:"" ?>">
                                    Rt <input type="text" size="4" id="VFRt" name="VFRt" value="<?php echo isset($stp['VFRt'])?$stp['VFRt']:"" ?>"></td></tr>
                            <tr><td colspan="2"><i><b>Facial weakness</b></i>:
                                    <input type="radio" id="FacialWeaknessLR" name="FacialWeaknessLR" value="l" <?php echo isset($stp['FacialWeaknessLR'])? ($stp['FacialWeaknessLR'] == "l"? "checked": "") : "" ?>>Lt
                                    <input type="radio" id="FacialWeaknessLR" name="FacialWeaknessLR" value="r" <?php echo isset($stp['FacialWeaknessLR'])? ($stp['FacialWeaknessLR'] == "r"? "checked": "") : "" ?>>Rt,
                                    <input type="radio" id="FacialWeaknessUL" name="FacialWeaknessUL" value="u" <?php echo isset($stp['FacialWeaknessUL'])? ($stp['FacialWeaknessUL'] == "u"? "checked": "") : "" ?>>UMN
                                    <input type="radio" id="FacialWeaknessUL" name="FacialWeaknessUL" value="l" <?php echo isset($stp['FacialWeaknessUL'])? ($stp['FacialWeaknessUL'] == "l"? "checked": "") : "" ?>>LMN</td></tr>
                            <tr><td colspan="2"><i><b>Tongue deviation</b></i>:
                                    <input type="radio" id="TongueDeviationYN" name="TongueDeviationYN" value="y" <?php echo isset($stp['TongueDeviationYN'])? ($stp['TongueDeviationYN'] == "y"? "checked": "") : "" ?>> Y (
                                    to
                                    <input type="radio" id="TongueDeviationLR" name="TongueDeviationLR" value="l" <?php echo isset($stp['TongueDeviationLR'])? ($stp['TongueDeviationLR'] == "l"? "checked": "") : "" ?>>Lt/
                                    <input type="radio" id="TongueDeviationLR" name="TongueDeviationLR" value="r" <?php echo isset($stp['TongueDeviationLR'])? ($stp['TongueDeviationLR'] == "r"? "checked": "") : "" ?>>Rt)
                                    <input type="radio" id="TongueDeviationYN" name="TongueDeviationYN" value="n" <?php echo isset($stp['TongueDeviationYN'])? ($stp['TongueDeviationYN'] == "n"? "checked": "") : "" ?>>N
                            <tr><td colspan="2"><i><b>Gag reflex</b></i>:
                                    Lt <input type="text" size="3" id="GagReflexL" name="GagReflexL" value="<?php echo isset($stp['GagReflexL'])?$stp['GagReflexL']:"" ?>">/
                                    Rt <input type="text" size="3" id="GagReflexR" name="GagReflexR" value="<?php echo isset($stp['GagReflexR'])?$stp['GagReflexR']:"" ?>">
                                    Uvula:
                                    <input type="radio" id="UvalaMD" name="UvalaMD" value="m" <?php echo isset($stp['UvalaMD'])? ($stp['UvalaMD'] == "m"? "checked": "") : "" ?>> midline /
                                    <input type="radio" id="UvalaMD" name="UvalaMD" value="d" <?php echo isset($stp['UvalaMD'])? ($stp['UvalaMD'] == "d"? "checked": "") : "" ?>> deviate to
                                    <input type="radio" id="UvalaLR" name="UvalaLR" value="l" <?php echo isset($stp['UvalaLR'])? ($stp['UvalaLR'] == "l"? "checked": "") : "" ?>> Lt /
                                    <input type="radio" id="UvalaLR" name="UvalaLR" value="r" <?php echo isset($stp['UvalaLR'])? ($stp['UvalaLR'] == "r"? "checked": "") : "" ?>>Rt</td></tr>
                            <tr><td colspan="2">
                                    <table cellspacing="0" style="margin: 10px">
                                        <tr><td width="80"><u><b>Motor</b></u>:</td><td style="border-right: 2px solid black">
                                                prox. <input type="text" size="1" id="MotorLTp" name="MotorLTp" value="<?php echo isset($stp['MotorLTp'])?$stp['MotorLTp']:"" ?>">/
                                                distal <input type="text" size="1" id="MotorLTd" name="MotorLTd" value="<?php echo isset($stp['MotorLTd'])?$stp['MotorLTd']:"" ?>"> &nbsp;</td><td style="border-right: black 2px">
                                                prox. <input type="text" size="1" id="MotorRTp" name="MotorRTp" value="<?php echo isset($stp['MotorRTp'])?$stp['MotorRTp']:"" ?>">/
                                                distal <input type="text" size="1" id="MotorRTd" name="MotorRTd" value="<?php echo isset($stp['MotorRTd'])?$stp['MotorRTd']:"" ?>"></td></tr>
                                        <tr><td></td><td style="border-right: 2px solid black;border-top: 2px solid black">
                                                prox. <input type="text" size="1" id="MotorLBp" name="MotorLBp" value="<?php echo isset($stp['MotorLBp'])?$stp['MotorLBp']:"" ?>">/
                                                distal <input type="text" size="1" id="MotorLBd" name="MotorLBd" value="<?php echo isset($stp['MotorLBd'])?$stp['MotorLBd']:"" ?>"></td><td style="border-top: 2px solid black">
                                                prox. <input type="text" size="1" id="MotorRBp" name="MotorRBp" value="<?php echo isset($stp['MotorRBp'])?$stp['MotorRBp']:"" ?>">/
                                                distal <input type="text" size="1" id="MotorRBd" name="MotorRBd" value="<?php echo isset($stp['MotorRBd'])?$stp['MotorRBd']:"" ?>"></td></tr>
                                    </table>
                                </td>
                            </tr>
                            <tr><td colspan="2"><i><b>Pronator drifting</b></i>:
                                    <input type="radio" id="PronatorDriftingLR" name="PronatorDriftingLR" value="l" <?php echo isset($stp['PronatorDriftingLR'])? ($stp['PronatorDriftingLR'] == "l"? "checked": "") : "" ?>>Lt/
                                    <input type="radio" id="PronatorDriftingLR" name="PronatorDriftingLR" value="r" <?php echo isset($stp['PronatorDriftingLR'])? ($stp['PronatorDriftingLR'] == "r"? "checked": "") : "" ?>>Rt</td></tr>
                            <tr><td colspan="2"><u><b>Cerebellar signs</b></u>:
                                    <input type="radio" id="CerebellarYN" name="CerebellarYN" value="y" <?php echo isset($stp['CerebellarYN'])? ($stp['CerebellarYN'] == "y"? "checked": "") : "" ?>>Y/
                                    <input type="radio" id="CerebellarYN" name="CerebellarYN" value="n" <?php echo isset($stp['CerebellarYN'])? ($stp['CerebellarYN'] == "n"? "checked": "") : "" ?>>N
                                    Gait ataxia
                                    <input type="radio" id="CerebellarGLR" name="CerebellarGLR" value="l" <?php echo isset($stp['CerebellarGLR'])? ($stp['CerebellarGLR'] == "l"? "checked": "") : "" ?>>Lt/
                                    <input type="radio" id="CerebellarGLR" name="CerebellarGLR" value="r" <?php echo isset($stp['CerebellarGLR'])? ($stp['CerebellarGLR'] == "r"? "checked": "") : "" ?>>Rt,
                                    trunkal ataxia
                                    <input type="radio" id="CerebellarTYN" name="CerebellarTYN" value="y" <?php echo isset($stp['CerebellarTYN'])? ($stp['CerebellarTYN'] == "y"? "checked": "") : "" ?>>Y/
                                    <input type="radio" id="CerebellarTYN" name="CerebellarTYN" value="n" <?php echo isset($stp['CerebellarTYN'])? ($stp['CerebellarTYN'] == "n"? "checked": "") : "" ?>>N
                                    , finger to nose
                                    <input type="radio" id="CerebellarFYN" name="CerebellarFYN" value="y" <?php echo isset($stp['CerebellarFYN'])? ($stp['CerebellarFYN'] == "y"? "checked": "") : "" ?>>Y/
                                    <input type="radio" id="CerebellarFYN" name="CerebellarFYN" value="n" <?php echo isset($stp['CerebellarFYN'])? ($stp['CerebellarFYN'] == "n"? "checked": "") : "" ?>>N
                                </td></tr>
                            <tr><td colspan="2">
                                    <table>
                                        <tr><td valign="top"><u><b>Sensory</b></u>:</td><td><?php echo html::image('assets/images/human_body.jpg',array('width' => '50', 'height' => '100')); ?></td>
                                            <td valign="top"><b><u>DTR:</u></b></td></tr>
                                    </table>
                                </td>
                            </tr>
                            <tr><td colspan="2">Neglect
                                    Lt <input type="text" size="3" id="NeglectLt" name="NeglectLt" value="<?php echo isset($stp['NeglectLt'])?$stp['NeglectLt']:"" ?>">
                                    Rt <input type="text" size="3" id="NeglectRt" name="NeglectRt" value="<?php echo isset($stp['NeglectRt'])?$stp['NeglectRt']:"" ?>"> BBK </td></tr>
                            <tr><td colspan="2">Proprioception
                                    Lt <input type="text" size="3" id="ProprioceptionLt" name="ProprioceptionLt" value="<?php echo isset($stp['ProprioceptionLt'])?$stp['ProprioceptionLt']:"" ?>">,
                                    Rt <input type="text" size="3" id="ProprioceptionRt" name="ProprioceptionRt" value="<?php echo isset($stp['ProprioceptionRt'])?$stp['ProprioceptionRt']:"" ?>"> </td></tr>
                            <tr><td colspan="2">
                                    Stereognosis
                                    Lt <input type="text" size="3" id="StereognosisLt" name="StereognosisLt" value="<?php echo isset($stp['StereognosisLt'])?$stp['StereognosisLt']:"" ?>">,
                                    Rt <input type="text" size="3" id="StereognosisRt" name="StereognosisRt" value="<?php echo isset($stp['StereognosisRt'])?$stp['StereognosisRt']:"" ?>">,
                                    Figure palm test
                                    Lt <input type="text" size="3" id="FigurePalmTestLt" name="FigurePalmTestLt" value="<?php echo isset($stp['FigurePalmTestLt'])?$stp['FigurePalmTestLt']:"" ?>">,
                                    Rt <input type="text" size="3" id="FigurePalmTestRt" name="FigurePalmTestRt" value="<?php echo isset($stp['FigurePalmTestRt'])?$stp['FigurePalmTestRt']:"" ?>"> </td></tr>

                            <tr><td colspan="2">
                                    <table style="margin: 10px; border: 1px solid black; padding: 5px" width="90%">
                                        <tr><td width="100"><u>
                                                    <b>Final Dx</b></u></td><td>
                                                <input type="radio" id="FinalDXHI" name="FinalDXHI" value="h" <?php echo isset($stp['FinalDXHI'])? ($stp['FinalDXHI'] == "h"? "checked": "") : "" ?>><b>Hemorrhagic stoke </b> type
                                                <input type="text" size="5" id="FinalDXHType" name="FinalDXHType" value="<?php echo isset($stp['FinalDXHType'])?$stp['FinalDXHType']:"" ?>"> </td></tr>
                                        <tr><td></td><td><input type="radio" id="FinalDXHI" name="FinalDXHI" value="i" <?php echo isset($stp['FinalDXHI'])? ($stp['FinalDXHI'] == "i"? "checked": "") : "" ?>><b>Ischemic stoke </b></td></tr>
                                        <tr><td><b>Vessel</b></td><td>
                                                <input type="radio" id="VesselAP" name="VesselAP" value="a" <?php echo isset($stp['VesselAP'])? ($stp['VesselAP'] == "a"? "checked": "") : "" ?>><b>Anterior circulation :
                                                    <input type="radio" id="VesselAc" name="VesselAc" value="a" <?php echo isset($stp['VesselAc'])? ($stp['VesselAc'] == "a"? "checked": "") : "" ?>> ACA /
                                                    <input type="radio" id="VesselAc" name="VesselAc" value="m" <?php echo isset($stp['VesselAc'])? ($stp['VesselAc'] == "m"? "checked": "") : "" ?>> MCA </b></td></tr>
                                        <tr><td></td><td>
                                                <input type="radio" id="VesselAP" name="VesselAP" value="p" <?php echo isset($stp['VesselAP'])? ($stp['VesselAP'] == "p"? "checked": "") : "" ?>><b>Posterior circulation: <br> &nbsp;&nbsp;&nbsp;&nbsp;
                                                    <input type="radio" id="VesselPc" name="VesselPc" value="pc" <?php echo isset($stp['VesselPc'])? ($stp['VesselPc'] == "pc"? "checked": "") : "" ?>> PCA /
                                                    <input type="radio" id="VesselPc" name="VesselPc" value="vb" <?php echo isset($stp['VesselPc'])? ($stp['VesselPc'] == "vb"? "checked": "") : "" ?>> VB /
                                                    <input type="radio" id="VesselPc" name="VesselPc" value="pi" <?php echo isset($stp['VesselPc'])? ($stp['VesselPc'] == "pi"? "checked": "") : "" ?>> PICA /
                                                    <input type="radio" id="VesselPc" name="VesselPc" value="ai" <?php echo isset($stp['VesselPc'])? ($stp['VesselPc'] == "ai"? "checked": "") : "" ?>> AICA /
                                                    <input type="radio" id="VesselPc" name="VesselPc" value="ce" <?php echo isset($stp['VesselPc'])? ($stp['VesselPc'] == "ce"? "checked": "") : "" ?>> Cerebellar </b></td></tr>
                                        <tr><td><b>Cause</b></td><td>
                                                <input type="radio" id="Cause" name="Cause" value="e" <?php echo isset($stp['Cause'])? ($stp['Cause'] == "e"? "checked": "") : "" ?>><b>Emboli :
                                                    <input type="radio" id="CauseE" name="CauseE"> cardiac ,
                                                    <input type="radio" id="CauseE" name="CauseE"> artery ,
                                                    <input type="radio" id="CauseE" name="CauseE"> unknown </b></td></tr>
                                        <tr><td></td><td>
                                                <input type="radio" id="Cause" name="Cause" value="t" <?php echo isset($stp['Cause'])? ($stp['Cause'] == "t"? "checked": "") : "" ?>><b>Thrombosis</b></td></tr>
                                        <tr><td></td><td>
                                                <input type="radio" id="Cause" name="Cause" value="l" <?php echo isset($stp['Cause'])? ($stp['Cause'] == "l"? "checked": "") : "" ?>><b>Lacunar stroke :
                                                    type
                                                    <select name="CauseLType" id="CauseLType">
                                                        <option value="pm" <?php echo isset($stp['CauseLType'])? ($stp['CauseLType'] == "pm"? "selected": "") : "" ?>>Pure motor syndrome</option>
                                                        <option value="ps" <?php echo isset($stp['CauseLType'])? ($stp['CauseLType'] == "ps"? "selected": "") : "" ?>>Pure sensory syndrome</option>
                                                        <option value="ah" <?php echo isset($stp['CauseLType'])? ($stp['CauseLType'] == "ah"? "selected": "") : "" ?>>Ataxic hemiparesis</option>
                                                        <option value="dc" <?php echo isset($stp['CauseLType'])? ($stp['CauseLType'] == "dc"? "selected": "") : "" ?>>dysarthria clumsy hand syndrome</option>
                                                        <option value="sm" <?php echo isset($stp['CauseLType'])? ($stp['CauseLType'] == "sm"? "selected": "") : "" ?>>Sensori-motor syndrome</option>
                                                    </select></b></td></tr>
                                        <tr><td></td><td>
                                                <input type="radio" id="Cause" name="Cause" value="o" <?php echo isset($stp['Cause'])? ($stp['Cause'] == "o"? "checked": "") : "" ?>><b>Others
                                                    <input type="text" size="15" id="CauseOther" name="CauseOther" value="<?php echo isset($stp['CauseOther'])?$stp['CauseOther']:"" ?>"></b></td></tr>
                                        <tr><td colspan="3"><b>Stage</b> :
                                                <input type="radio" id="Stage" name="Stage" value="s" <?php echo isset($stp['Stage'])? ($stp['Stage'] == "s"? "checked": "") : "" ?>> Stable/
                                                <input type="radio" id="Stage" name="Stage" value="p" <?php echo isset($stp['Stage'])? ($stp['Stage'] == "p"? "checked": "") : "" ?>> progressive/
                                                <input type="radio" id="Stage" name="Stage" value="c" <?php echo isset($stp['Stage'])? ($stp['Stage'] == "c"? "checked": "") : "" ?>> completed/
                                                <input type="radio" id="Stage" name="Stage" value="i" <?php echo isset($stp['Stage'])? ($stp['Stage'] == "i"? "checked": "") : "" ?>> improved/
                                                <input type="radio" id="Stage" name="Stage" value="t" <?php echo isset($stp['Stage'])? ($stp['Stage'] == "t"? "checked": "") : "" ?>> TIA</td></tr>
                                    </table>
                                </td></tr>
                            <tr><td colspan="2"><b>Other</b>
                                    <input type="text" size="40" id="stp_others" name="stp_others" value="<?php echo isset($stp['stp_others'])?$stp['stp_others']:"" ?>"> </td></tr>
                            <tr><td colspan="2"><b>Provisional Diagnosis</b>
                                    <input type="text" size="40" id="ProvisionalDiagnosis" name="ProvisionalDiagnosis" value="<?php echo isset($stp['ProvisionalDiagnosis'])?$stp['ProvisionalDiagnosis']:"" ?>"> </td></tr>
                            <tr><td colspan="2"><b>CT scan</b>
                                    <input type="text" size="40" id="CTScan" name="CTScan" value="<?php echo isset($stp['CTScan'])?$stp['CTScan']:"" ?>"> </td></tr>
                            <tr><td colspan="2"><b>RX</b>
                                    <input type="text" size="40" id="RX" name="RX" value="<?php echo isset($stp['RX'])?$stp['RX']:"" ?>"> </td></tr>
                        </tbody>
                    </table>
                </div>

                <div id="tabs-4">
                    <table id="users" class="ui-widget ui-widget-content ui-corner-all" width="100%" style="margin-top: 10px;padding-bottom: 10px;">
                        <thead>
                            <tr class="ui-widget-header ">
                                <th colspan="7" align="left" style="padding: 10px">Laboratory screen for exclusion</th>
                            </tr>
                        </thead>
                        <tbody>
                            <tr><td><input type="checkbox" id="CTscanYN"name="CTscanYN" <?php echo isset($lab['CTscanYN'])? ($lab['CTscanYN'] == "true"? "checked": "") : "" ?>>CT scan/
                                    MRI result <input type="text" size="5" id="CTMRI" name="CTMRI" value="<?php echo isset($lab['CTMRI'])?$lab['CTMRI']:"" ?>"> ASPECT score
                                    <input type="text" size="5" id="CTASPECT" name="CTASPECT" value="<?php echo isset($lab['CTASPECT'])?$lab['CTASPECT']:"" ?>"> </td></tr>
                            <tr><td>&nbsp;&nbsp;
                                    <input type="checkbox" id="CTNoICHYN" name="CTNoICHYN" <?php echo isset($lab['CTNoICHYN'])? ($lab['CTNoICHYN'] == "true"? "checked": "") : "" ?>> No ICH
                                    <input type="checkbox" id="CTnobrainYN" name="CTnobrainYN" <?php echo isset($lab['CTnobrainYN'])? ($lab['CTnobrainYN'] == "true"? "checked": "") : "" ?>> no brain edema/shiffing </td></tr>
                            <tr><td><input type="checkbox" id="CTPerfusionYN" name="CTPerfusionYN" <?php echo isset($lab['CTPerfusionYN'])? ($lab['CTPerfusionYN'] == "true"? "checked": "") : "" ?>> CT Perfusion</td></tr>
                            <tr><td><input type="checkbox" id="MRIYN" name="MRIYN" <?php echo isset($lab['MRIYN'])? ($lab['MRIYN'] == "true"? "checked": "") : "" ?>>
                                    MRI result <input type="text" size="5" id="MRIResult" name="MRIResult" value="<?php echo isset($lab['MRIResult'])?$lab['MRIResult']:"" ?>"> </td></tr>
                            <tr><td>&nbsp;&nbsp;<input type="checkbox" id="MRINoICHYN" name="MRINoICHYN" <?php echo isset($lab['MRINoICHYN'])? ($lab['MRINoICHYN'] == "true"? "checked": "") : "" ?>> No ICH
                                    <input type="checkbox" id="MRInobrainYN" name="MRInobrainYN" <?php echo isset($lab['MRInobrainYN'])? ($lab['MRInobrainYN'] == "true"? "checked": "") : "" ?>> no brain edema/shiffing </td></tr>
                            <tr><td>&nbsp;&nbsp;<input type="checkbox" id="MRIDWI30YN" name="MRIDWI30YN" <?php echo isset($lab['MRIDWI30YN'])? ($lab['MRIDWI30YN'] == "true"? "checked": "") : "" ?>> DWI &le; 30% of MCA territory </td></tr>
                            <tr><td>&nbsp;&nbsp;<input type="checkbox" id="MRIDWIPWIYN" name="MRIDWIPWIYN" <?php echo isset($lab['MRIDWIPWIYN'])? ($lab['MRIDWIPWIYN'] == "true"? "checked": "") : "" ?>> DWI / PWI mismatch </td></tr>
                            <tr><td><input type="checkbox" id="MRAYN" name="MRAYN" <?php echo isset($lab['MRAYN'])? ($lab['MRAYN'] == "true"? "checked": "") : "" ?>> MRA</td></tr>
                            <tr><td>&nbsp;&nbsp;<input type="checkbox" id="MRAMCAYN" name="MRAMCAYN" <?php echo isset($lab['MRAMCAYN'])? ($lab['MRAMCAYN'] == "true"? "checked": "") : "" ?>> MCA
                                    <input type="radio" value="s" id="MRAMCAso" name="MRAMCAso" <?php echo isset($lab['MRAMCAso'])? ($lab['MRAMCAso'] == "s"? "checked": "") : "" ?>> stenosis/
                                    <input type="radio" value="o" id="MRAMCAso" name="MRAMCAso" <?php echo isset($lab['MRAMCAso'])? ($lab['MRAMCAso'] == "o"? "checked": "") : "" ?>> occlusion </td></tr>
                            <tr><td>&nbsp;&nbsp;<input type="checkbox" id="MRAACAYN" name="MRAACAYN" <?php echo isset($lab['MRAACAYN'])? ($lab['MRAACAYN'] == "true"? "checked": "") : "" ?>> ACA
                                    <input type="radio" value="s" id="MRAACAso" name="MRAACAso" <?php echo isset($lab['MRAACAso'])? ($lab['MRAACAso'] == "s"? "checked": "") : "" ?>> stenosis/
                                    <input type="radio" value="o" id="MRAACAso" name="MRAACAso" <?php echo isset($lab['MRAACAso'])? ($lab['MRAACAso'] == "o"? "checked": "") : "" ?>> occlusion </td></tr>
                            <tr><td>&nbsp;&nbsp;<input type="checkbox" id="MRABAYN" name="MRABAYN" <?php echo isset($lab['MRABAYN'])? ($lab['MRABAYN'] == "true"? "checked": "") : "" ?>> BA
                                    <input type="radio" value="s" id="MRABAso" name="MRABAso" <?php echo isset($lab['MRABAso'])? ($lab['MRABAso'] == "s"? "checked": "") : "" ?>> stenosis/
                                    <input type="radio" value="o" id="MRABAso" name="MRABAso" <?php echo isset($lab['MRABAso'])? ($lab['MRABAso'] == "o"? "checked": "") : "" ?>> occlusion </td></tr>
                            <tr><td>&nbsp;&nbsp;<input type="checkbox" id="MRAICAYN" name="MRAICAYN" <?php echo isset($lab['MRAICAYN'])? ($lab['MRAICAYN'] == "true"? "checked": "") : "" ?>> ICA
                                    <input type="radio" value="s" id="MRAICAso" name="MRAICAso" <?php echo isset($lab['MRAICAso'])? ($lab['MRAICAso'] == "s"? "checked": "") : "" ?>> stenosis/
                                    <input type="radio" value="o" id="MRAICAso" name="MRAICAso" <?php echo isset($lab['MRAICAso'])? ($lab['MRAICAso'] == "o"? "checked": "") : "" ?>> occlusion </td></tr>
                            <tr><td>&nbsp;&nbsp;<input type="checkbox" id="MRAotherYN" name="MRAotherYN" <?php echo isset($lab['MRAotherYN'])? ($lab['MRAotherYN'] == "true"? "checked": "") : "" ?>> other
                                    <input type="text" size="5" id="MRAother" name="MRAother" value="<?php echo isset($lab['MRAother'])?$lab['MRAother']:"" ?>"> </td></tr>
                            <tr><td><hr></td></tr>
                            <tr><td>Blood test result PG <input type="text" size="3" id="BloodPG" name="BloodPG" value="<?php echo isset($lab['BloodPG'])?$lab['BloodPG']:"" ?>">
                                    PT <input type="text" size="3" id="BloodPT" name="BloodPT" value="<?php echo isset($lab['BloodPT'])?$lab['BloodPT']:"" ?>">
                                    PTT <input type="text" size="3" id="BloodPTT" name="BloodPTT" value="<?php echo isset($lab['BloodPTT'])?$lab['BloodPTT']:"" ?>">
                                    PLT <input type="text" size="3" id="BloodPLT" name="BloodPLT" value="<?php echo isset($lab['BloodPLT'])?$lab['BloodPLT']:"" ?>"></td></tr>
                            <tr><td>
                                    <table style="margin-left: 20px">
                                        <tr><td width="400">
                                                <input type="checkbox" id="BloodPGYN" name="BloodPGYN" <?php echo isset($lab['BloodPGYN'])? ($lab['BloodPGYN'] == "true"? "checked": "") : "" ?>> PG > 50 < 400 mg/dl</td><td>
                                                <input type="checkbox" id="BloodPLTYN" name="BloodPLTYN" <?php echo isset($lab['BloodPLTYN'])? ($lab['BloodPLTYN'] == "true"? "checked": "") : "" ?>> Plt > 100,000</td></tr>
                                        <tr><td><input type="checkbox" id="BloodINRYN" name="BloodINRYN" <?php echo isset($lab['BloodINRYN'])? ($lab['BloodINRYN'] == "true"? "checked": "") : "" ?>> INR < 1.7 </td><td>
                                                <input type="checkbox" id="BloodPTTYN" name="BloodPTTYN" <?php echo isset($lab['BloodPTTYN'])? ($lab['BloodPTTYN'] == "true"? "checked": "") : "" ?>> PTT not prolonged</td></tr>
                                    </table>
                                </td>
                            </tr>

                        </tbody>
                    </table>
                </div>
                <div id="tabs-5">
                    <table width="100%" class="ui-widget ui-widget-content ui-corner-all">
                        <tr class="ui-widget-header ">
                            <td colspan="3">ข้อบ่งชี้</td>
                        </tr>
                        <tr><td><input type="checkbox" id="estimate_i1" name="estimate_i1" <?php echo isset($est['estimate_i1'])? ($est['estimate_i1'] == "true"? "checked": "") : "" ?>></td><td>1. มีอาการของสมองขาดเลือดภายใน 3 ชั่วโมง</td></tr>
                        <tr bgcolor="#E4E4E4"><td><input type="checkbox" id="estimate_i2" <?php echo isset($est['estimate_i2'])? ($est['estimate_i2'] == "true"? "checked": "") : "" ?> name="estimate_i2" ></td><td>2. มีความผิดปกติทางระบบประสาทที่ตรวจพบได้</td></tr>
                        <tr><td><input type="checkbox" id="estimate_i3" name="estimate_i3" <?php echo isset($est['estimate_i3'])? ($est['estimate_i3'] == "true"? "checked": "") : "" ?>></td><td>3. ผลการตรวจเอกซเรย์คอมพิวเตอร์สมองไม่พบว่ามีเลือดออกในเนื้อสมองหรือเลือดออกในชั้นใต้เยื่อหุ้มสมอง</td></tr>
                    </table>
                    <br>
                    <table width="100%" class="ui-widget ui-widget-content ui-corner-all" >
                        <tr class="ui-widget-header "><td colspan="3">ข้อห้าม</td></tr>

                        <tr><td>
                                <input type="checkbox" id="estimate_d1" name="estimate_d1" <?php echo isset($est['estimate_d1'])? ($est['estimate_d1'] == "true"? "checked": "") : "" ?>></td><td>1. มีประวัติเลือดออกในสมองมาก่อน</td></tr>
                        <tr bgcolor="#E4E4E4"><td>
                                <input type="checkbox" id="estimate_d2" name="estimate_d2" <?php echo isset($est['estimate_d2'])? ($est['estimate_d2'] == "true"? "checked": "") : "" ?>></td><td>2. มีประวัติบาดเจ็บที่ศีรษะรุนแรงภายใน 3 เดือน</td></tr>
                        <tr><td><input type="checkbox" id="estimate_d3" name="estimate_d3" <?php echo isset($est['estimate_d3'])? ($est['estimate_d3'] == "true"? "checked": "") : "" ?>></td><td>3. มีประวัติผ่าตัดใหญ่ภายใน 14 วัน</td></tr>
                        <tr bgcolor="#E4E4E4"><td>
                                <input type="checkbox" id="estimate_d4" name="estimate_d4" <?php echo isset($est['estimate_d4'])? ($est['estimate_d4'] == "true"? "checked": "") : "" ?>></td><td>4. มีเลือดออกในทางเดินอาหาร หรือทางเดินปัสสาวะภายใน 21 วัน</td></tr>
                        <tr><td><input type="checkbox" id="estimate_d5" name="estimate_d5" <?php echo isset($est['estimate_d5'])? ($est['estimate_d5'] == "true"? "checked": "") : "" ?>></td><td>5. ผู้ป่วยที่มีอาการทางระบบประสาทดีขึ้นเองอย่างมากในเวลาอันรวดเร็ว หรือมีอาการน้อยก่อให้เกิดความพิการที่ไม่รุนแรง เช่น ชา เล็กน้อยเพียงอย่างเดียว</td></tr>
                        <tr bgcolor="#E4E4E4"><td>
                                <input type="checkbox" id="estimate_d6" name="estimate_d6" <?php echo isset($est['estimate_d6'])? ($est['estimate_d6'] == "true"? "checked": "") : "" ?>></td><td>6. มีอาการชักแต่เริ่มแรก</td></tr>
                        <tr><td><input type="checkbox" id="estimate_d7" name="estimate_d7" <?php echo isset($est['estimate_d7'])? ($est['estimate_d7'] == "true"? "checked": "") : "" ?>></td><td>7. มีประวัติกล้ามเนื้อหัวใจขาดเลือดเฉียบพลันในช่วงเวลาอันใกล้</td></tr>
                        <tr bgcolor="#E4E4E4"><td>
                                <input type="checkbox" id="estimate_d8" name="estimate_d8" <?php echo isset($est['estimate_d8'])? ($est['estimate_d8'] == "true"? "checked": "") : "" ?>></td><td>8. ความดันโลหิตช่วงก่อนให้การรักษาสูงโดยความดันซิสโตลิคสูงกว่า 185 มม.ปรอทหรือความดันไดแอสโตลิคสูงกว่า 110 มม.ปรอท</td></tr>
                        <tr><td><input type="checkbox" id="estimate_d9" name="estimate_d9" <?php echo isset($est['estimate_d9'])? ($est['estimate_d9'] == "true"? "checked": "") : "" ?>></td><td>9. มีระดับน้ำตาลในเลือดต่ำกว่า 50 มก/ดล. หรือสูงกว่า 400 มก/ดล.</td></tr>
                        <tr bgcolor="#E4E4E4"><td>
                                <input type="checkbox" id="estimate_d10" name="estimate_d10" <?php echo isset($est['estimate_d10'])? ($est['estimate_d10'] == "true"? "checked": "") : "" ?>></td><td>10. มีปริมาณเกล็ดเลือดน้อยกว่า 100,000/mm3</td></tr>
                        <tr><td><input type="checkbox" id="estimate_d11" name="estimate_d11" <?php echo isset($est['estimate_d11'])? ($est['estimate_d11'] == "true"? "checked": "") : "" ?>></td><td>11. ได้รับยา heparin ภายใน 48 ชั่วโมงและมีค่า partial thromboplastin time(PTT) ผิดปกติ</td></tr>
                        <tr bgcolor="#E4E4E4"><td>
                                <input type="checkbox" id="estimate_d12" name="estimate_d12" <?php echo isset($est['estimate_d12'])? ($est['estimate_d12'] == "true"? "checked": "") : "" ?>></td><td>12. ได้รับยาต้านการแข็งตัวของเลือดโดยมีค่า protrombin time(PT) มากกว่า 15 วินาที หรือมีค่า international normalized ratio (INR) มากกว่า 1.7 </td></tr>
                    </table>
                </div>
            </div>
            <table width="100%"><tr><td align="center" colspan="3"></td></tr></table>
        </td>
    </tr>
</table>
</div>